#!/bin/bash
####
yesterday=`date -d "yesterday" +%Y-%m-%d`
Today=`date +%Y-%m-%d`

nginx_log_dir=/var/log/nginx
cd ${nginx_log_dir}
awk '{print $1}' access${yesterday}-0[1-9].log access${yesterday}-1[0-9].log access${yesterday}-2[0-3].log access${Today}-00.log|sort|uniq|wc -l